//
//  Authorization.h
//  各种权限
//
//  Created by 1 on 2017/11/27.
//  Copyright © 2017年 1. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "XPSingleton.h"

@interface Authorization : NSObject
SingletonH(Authorization)

/** 网络权限 */
+ (BOOL)getNetAuthorizationStatusWithAlert;
+ (BOOL)getNetAuthorizationStatusWithoutAlert;
/** 网络变化  block:已联网操作   block1:未联网操作 */
+ (void)getNetAuthorizationWithBlock:(void(^)(void))block block:(void(^)(void))block1;
/** 麦克风权限 */
+ (BOOL)checkMicroPhoneAuthorizationStatus;
+ (void)getMicroPhoneAuthorizationWithBlock:(void(^)(void))block;
/** 相机权限 */
+ (BOOL)checkCameraAuthorizationStatus;
+ (void)getCameraAuthorizationWithCancelBlk:(void(^)(void))cancelBlk doneBlk:(void(^)(void))doneBlk;
/** 相册权限 */
+ (BOOL)checkPhotoAlbumAuthorizationStatus;
+ (void)getPhotoAlbumAuthorizationWithBlock:(void(^)(void))block;
/** 定位权限 */
//+ (BOOL)checkLocationAuthorizationStatus;
//+ (void)getLocationAuthorizationAlways:(BOOL)type withBlock:(void(^)(void))block;
/** 推送权限 */
+ (BOOL)checkNotificationAuthorizationStatus;
+ (void)getNotificationAuthorizationWithBlock:(void(^)(void))block;

/** 弹框 */
+ (void)showAlertWithMsg:(NSString *)msg;

//podfile 文件添加 inhibit_all_warnings! 可消除使用 pod 安装三方产生的警告
//Other Warning Flags 添加 -Wno-deprecated-declarations 消除弃用警告

@end
